//
//  WmcTeamCloudPhotoCell.swift
//  YPWatermarkCamera
//
//  Created by yupao_ios_macmini06 on 2022/9/21.
//

import SnapKit
import UIKit

class WmcTeamCloudPhotoCell: WmcCloudPhotoCell {
    let cell_width = (Wmc_screenWidth - 82 - 12) / 3.0

    override func makeUI() {
        super.makeUI()

        titleLabel.font = 21.yp.uiFont(weight: .semibold)

        titleView.snp.remakeConstraints { make in
            make.top.equalTo(0)
            make.left.right.equalToSuperview()
            make.height.equalTo(42)
        }
    }

    override func createGradientLayer() -> CAGradientLayer {
        let gradientLayer = CAGradientLayer()
        gradientLayer.colors = [
            "#000000".yp.cgColor(0.6),
            UIColor.clear.cgColor,
        ]
        gradientLayer.locations = [0, 1]
        gradientLayer.startPoint = CGPoint(x: 0.5, y: 0.0)
        gradientLayer.endPoint = CGPoint(x: 0.5, y: 1)
        gradientLayer.frame = CGRect(x: 0, y: 0, width: cell_width, height: 35)
        return gradientLayer
    }
}
